#include <cstdio>
#include <cstring>

int f[ 101 ][ 101 ];

int max( int a, int b ) { return ( a > b ) ?a :b; }
int min( int a, int b ) { return ( a < b ) ?a :b; }
int n, t, q, a[ 101 ], b[ 101 ];

void init( )
{
    int i;
    for ( i = 0; i < n; i++ )
        scanf("%d%d", &a[ i ], &b[ i ]);
    memset( f, 0, sizeof( f ) );
}

void work( )
{
    int i, j, k, p, l, c;
    for ( i = 1; q * ( i - 1 ) < 100; i++ )
    {
        for ( j = 0; j <= 100; j++ )
        {
            c = min( 100, j + t );
            f[ i ][ c ] = f[ i - 1 ][ j ] + 1;
            for ( k = 0; k < n; k++ )
                if ( j >= a[ k ] )
                {
                    c = min( 100, j - a[ k ] + t );
                    f[ i ][ c ] = max( f[ i ][ c ], f[ i - 1 ][ j ] + b[ k ] );
                }
            if ( f[ i ][ c ] >= 100 )
            {
                printf("%d\n", i);
                return ;
            }
        }
    }
    puts("My god");
}

int main( )
{
    while ( scanf("%d%d%d", &n, &t, &q) )
    {
        if ( n == 0 && t == 0 && q == 0 )
            break;
        init( );
        work( );
    }
    return 0;
}
